package com.warm.common.entity;

import lombok.Data;

import javax.validation.constraints.Email;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;

@Data
public class Validator {

    @NotNull(message = "id 不能为空")
    private Integer id;

    @NotNull(message = "name 不能为空")
    private String name;

    @NotNull(message = "账号不能为空")
    @Size(min = 6, max = 8, message = "账号必须6-8个字符")
    private String account;

    @NotNull(message = "邮箱不能为空")
    @Email(message = "邮箱格式不正确")
    private String email;

}
